#pragma once
#include "vector3.h"
#include "Types.h"
//
//	Cube
//
const vector3 cubePoints[] = {
	vector3(0,0,1),	// A/0
	vector3(1,0,1),	// B/1
	vector3(1,1,1),	// C/2
	vector3(0,1,1),	// D/3
	vector3(0,0,0),	// E/4
	vector3(1,0,0),	// F/5
	vector3(1,1,0),	// G/6
	vector3(0,1,0)};// H/7

const vector3 cubePointsFront[] = {
	cubePoints[0], cubePoints[1], cubePoints[3], cubePoints[2] };
const vector3 cubePointsBack[] = {
	cubePoints[5], cubePoints[4], cubePoints[6], cubePoints[7] };
const vector3 cubePointsLeft[] = {
	cubePoints[4], cubePoints[0], cubePoints[7], cubePoints[3] };
const vector3 cubePointsRight[] = {
	cubePoints[1], cubePoints[5], cubePoints[2], cubePoints[6] };
const vector3 cubePointsBottom[] = {
	cubePoints[4], cubePoints[5], cubePoints[0], cubePoints[1] };
const vector3 cubePointsTop[] = {
	cubePoints[3], cubePoints[2], cubePoints[7], cubePoints[6] };

const vector3 cubeNormals[] = {
	vector3(-1,-1,1).Normalize(),
	vector3(1,-1,1).Normalize(),
	vector3(1,1,1).Normalize(),
	vector3(-1,1,1).Normalize(),
	vector3(-1,-1,-1).Normalize(),
	vector3(1,1,1).Normalize(),
	vector3(1,1,1).Normalize(),
	vector3(1,1,1).Normalize() };

const vector3 cubeNormalsFront[] = {
	cubeNormals[0], cubeNormals[1], cubeNormals[3], cubeNormals[2] };
const vector3 cubeNormalsBack[] = {
	cubeNormals[5], cubeNormals[4], cubeNormals[6], cubeNormals[7] };
const vector3 cubeNormalsLeft[] = {
	cubeNormals[4], cubeNormals[0], cubeNormals[7], cubeNormals[3] };
const vector3 cubeNormalsRight[] = {
	cubeNormals[1], cubeNormals[5], cubeNormals[2], cubeNormals[6] };
const vector3 cubeNormalsBottom[] = {
	cubeNormals[4], cubeNormals[5], cubeNormals[0], cubeNormals[1] };
const vector3 cubeNormalsTop[] = {
	cubeNormals[3], cubeNormals[2], cubeNormals[7], cubeNormals[6] };

const uint cubeElementsFront[] = {
	0, 1, 3, 2 };
const uint cubeElementsBack[] = {
	5, 4, 6, 7 };
const uint cubeElementsLeft[] = {
	4, 0, 7, 3 };
const uint cubeElementsRight[] = {
	1, 5, 2, 6 };
const uint cubeElementsBottom[] = {
	4, 5, 0, 1 };
const uint cubeElementsTop[] = {
	3, 2, 7, 6 };

const vector2 cubeTexCoords[] = {
	vector2(0.0f,1.0f),
	vector2(1.0f,1.0f),
	vector2(0.0f,0.0f),
	vector2(1.0f,0.0f)
	 };

extern const vector3 *cubeSidePoints[];
extern const vector3 *cubeSideNormals[];
const vector3 cubeFaceNormals[] = { vector3(0,1,0), vector3(0,-1,0), vector3(-1,0,0),
	vector3(1,0,0), vector3(0,0,1), vector3(0,0,-1)};

const uint cubeElementCount = 8;
const uint cubeSideElementCount = 4;
//
//	Cross
//
const vector3 crossPoints[] = {
	//Plane 1
	vector3(0.0f, 0.0f, 0.5f),
	vector3(1.0f, 0.0f, 0.5f),
	vector3(0.0f, 1.0f, 0.5f),
	vector3(1.0f, 1.0f, 0.5f),
	//Plane 2
	vector3(0.5f, 0.0f, 0.0f),
	vector3(0.5f, 0.0f, 1.0f),
	vector3(0.5f, 1.0f, 0.0f),
	vector3(0.5f, 1.0f, 1.0f) 
};
const uint crossElementsXY[] = {
	0, 1, 2, 3};
const uint crossElementsYZ[] = {
	4, 5, 6, 7};
const uint crossElementCount = 4;
//
//	Billboard
//
const vector3 unitQuadPoints[] = {
	vector3(0.0f, 0.0f, 0.0f),
	vector3(1.0f, 0.0f, 0.0f),
	vector3(0.0f, 1.0f, 0.0f),
	vector3(1.0f, 1.0f, 0.0f) };
const vector3 unitQuadLines[] = {
	vector3(0.0f, 0.0f, 0.0f),
	vector3(1.0f, 0.0f, 0.0f),
	vector3(1.0f, 1.0f, 0.0f),
	vector3(0.0f, 1.0f, 0.0f),
	vector3(0.0f, 0.0f, 0.0f)};
const vector2 unitQuadTexCoords2[] = {
	vector2(1.0f,1.0f),
	vector2(0.0f,1.0f),
	vector2(1.0f,0.0f),
	vector2(0.0f,0.0f) };
const vector2 unitQuadTexCoords[] = {
	vector2(0.0f,0.0f),
	vector2(1.0f,0.0f),
	vector2(0.0f,1.0f),
	vector2(1.0f,1.0f)};
const uint unitQuadElements[] = {
	0, 1, 3, 2 };
const uint unitQuadElementCount = 4;
const uint unitQuadLinesElementCount = 5;